import request from '@/utils/request'

// 查询作业任务明细信息列表
export function listDetails(query) {
    return request({
        url: '/kettle/details/list',
        method: 'get',
        params: query
    })
}

// 查询作业任务明细信息详细
export function getDetails(id) {
    return request({
        url: '/kettle/details/' + id,
        method: 'get'
    })
}

// 新增作业任务明细信息
export function addDetails(data) {
    return request({
        url: '/kettle/details',
        method: 'post',
        data: data
    })
}

// 修改作业任务明细信息
export function updateDetails(data) {
    return request({
        url: '/kettle/details',
        method: 'put',
        data: data
    })
}

// 删除作业任务明细信息
export function delDetails(id) {
    return request({
        url: '/kettle/details/' + id,
        method: 'delete'
    })
}

// 初始化查询
export function init() {
  return request({
    url: '/kettle/details/init',
    method: 'put'
  })
}
/**
 * 保存顺序
 * @param data
 */
export function handleUpdateOrderNum(data){
  return request({
    url: '/kettle/details/handleUpdateOrderNum',
    method: 'post',
    data: data
  })
}


// 执行作业任务明细
export function executeJobTaskDetail(executeJson) {
  return request({
    url: '/kettle/jobExecute/executeJobTaskDetail',
    method: 'post',
    data: executeJson
  })
}
